package com.wmh.baseservice.merchant.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.Version;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.List;

/**
 * @author wmh generator
 * @since 2022-04-09
 */
@ApiModel(value="MerchantActivity对象", description="商家活动表")
public class MerchantActivity implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "状态:	0")
    private Integer status;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "版本号")
    @Version
    private Integer version;

    private Date createTime;

    private Date updateTime;

    @ApiModelProperty(value = "活动标题")
    private String title;

    @ApiModelProperty(value = "简介")
    private String overview;

    @ApiModelProperty(value = "经度")
    private String lat;

    @ApiModelProperty(value = "维度")
    private String lng;

    @ApiModelProperty(value = "活动详情")
    private String content;

    @ApiModelProperty(value = "报名人数")
    private Integer registerCount;

    @ApiModelProperty(value = "详细地址")
    private String address;

    @ApiModelProperty(value = "商家id")
    private Long merchantId;

    @ApiModelProperty(value = "0免费 1收费")
    private Integer hasCost;

    @ApiModelProperty(value = "活动费用")
    private BigDecimal cost;

    @ApiModelProperty(value = "活动背景图")
    private String banner;

    @ApiModelProperty(value = "活动开始时间")
    private Date openTime;

    @ApiModelProperty(value = "活动结束时间")
    private Date overTime;

    @ApiModelProperty(value = "静态资源路径id")
    private Long UrlId;

    public Long getId() {
        return id;
    }

    public MerchantActivity setId(Long id) {
        this.id = id;
        return this;
    }
    public Integer getStatus() {
        return status;
    }

    public MerchantActivity setStatus(Integer status) {
        this.status = status;
        return this;
    }
    public String getRemark() {
        return remark;
    }

    public MerchantActivity setRemark(String remark) {
        this.remark = remark;
        return this;
    }
    public Integer getVersion() {
        return version;
    }

    public MerchantActivity setVersion(Integer version) {
        this.version = version;
        return this;
    }
    public Date getCreateTime() {
        return createTime;
    }

    public MerchantActivity setCreateTime(Date createTime) {
        this.createTime = createTime;
        return this;
    }
    public Date getUpdateTime() {
        return updateTime;
    }

    public MerchantActivity setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
        return this;
    }
    public String getTitle() {
        return title;
    }

    public MerchantActivity setTitle(String title) {
        this.title = title;
        return this;
    }
    public String getOverview() {
        return overview;
    }

    public MerchantActivity setOverview(String overview) {
        this.overview = overview;
        return this;
    }
    public String getLat() {
        return lat;
    }

    public MerchantActivity setLat(String lat) {
        this.lat = lat;
        return this;
    }
    public String getLng() {
        return lng;
    }

    public MerchantActivity setLng(String lng) {
        this.lng = lng;
        return this;
    }
    public String getContent() {
        return content;
    }

    public MerchantActivity setContent(String content) {
        this.content = content;
        return this;
    }
    public Integer getRegisterCount() {
        return registerCount;
    }

    public MerchantActivity setRegisterCount(Integer registerCount) {
        this.registerCount = registerCount;
        return this;
    }
    public String getAddress() {
        return address;
    }

    public MerchantActivity setAddress(String address) {
        this.address = address;
        return this;
    }
    public Long getMerchantId() {
        return merchantId;
    }

    public MerchantActivity setMerchantId(Long merchantId) {
        this.merchantId = merchantId;
        return this;
    }
    public Integer getHasCost() {
        return hasCost;
    }

    public MerchantActivity setHasCost(Integer hasCost) {
        this.hasCost = hasCost;
        return this;
    }
    public BigDecimal getCost() {
        return cost;
    }

    public MerchantActivity setCost(BigDecimal cost) {
        this.cost = cost;
        return this;
    }
    public String getBanner() {
        return banner;
    }

    public MerchantActivity setBanner(String banner) {
        this.banner = banner;
        return this;
    }
    public Date getOpenTime() {
        return openTime;
    }

    public MerchantActivity setOpenTime(Date openTime) {
        this.openTime = openTime;
        return this;
    }
    public Date getOverTime() {
        return overTime;
    }

    public MerchantActivity setOverTime(Date overTime) {
        this.overTime = overTime;
        return this;
    }

    public Long getUrlId() {
        return UrlId;
    }

    public MerchantActivity setUrlId(Long urlId) {
        UrlId = urlId;
        return this;
    }

    public static final String ID = "id";

    public static final String STATUS = "status";

    public static final String REMARK = "remark";

    public static final String VERSION = "version";

    public static final String CREATE_TIME = "create_time";

    public static final String UPDATE_TIME = "update_time";

    public static final String TITLE = "title";

    public static final String OVERVIEW = "overview";

    public static final String LAT = "lat";

    public static final String LNG = "lng";

    public static final String CONTENT = "content";

    public static final String REGISTER_COUNT = "register_count";

    public static final String ADDRESS = "address";

    public static final String MERCHANT_ID = "merchant_id";

    public static final String HAS_COST = "has_cost";

    public static final String COST = "cost";

    public static final String BANNER = "banner";

    public static final String OPEN_TIME = "open_time";

    public static final String OVER_TIME = "over_time";

    public static final String URL_ID = "url_id";


    @Override
    public String toString() {
        return "MerchantActivity{" +
                "id=" + id +
                ", status=" + status +
                ", remark='" + remark + '\'' +
                ", version=" + version +
                ", createTime=" + createTime +
                ", updateTime=" + updateTime +
                ", title='" + title + '\'' +
                ", overview='" + overview + '\'' +
                ", lat='" + lat + '\'' +
                ", lng='" + lng + '\'' +
                ", content='" + content + '\'' +
                ", registerCount=" + registerCount +
                ", address='" + address + '\'' +
                ", merchantId=" + merchantId +
                ", hasCost=" + hasCost +
                ", cost=" + cost +
                ", banner='" + banner + '\'' +
                ", openTime=" + openTime +
                ", overTime=" + overTime +
                ", UrlId=" + UrlId +
                '}';
    }

    public final static String[] getFields(String ...noField){
        List<String> list = new ArrayList<>(Arrays.asList(
            MerchantActivity.ID
            ,MerchantActivity.STATUS
            ,MerchantActivity.REMARK
            ,MerchantActivity.VERSION
            ,MerchantActivity.CREATE_TIME
            ,MerchantActivity.UPDATE_TIME
            ,MerchantActivity.TITLE
            ,MerchantActivity.OVERVIEW
            ,MerchantActivity.LAT
            ,MerchantActivity.LNG
            ,MerchantActivity.CONTENT
            ,MerchantActivity.REGISTER_COUNT
            ,MerchantActivity.ADDRESS
            ,MerchantActivity.MERCHANT_ID
            ,MerchantActivity.HAS_COST
            ,MerchantActivity.COST
            ,MerchantActivity.BANNER
            ,MerchantActivity.OPEN_TIME
            ,MerchantActivity.OVER_TIME
            ,MerchantActivity.URL_ID
        ));
        list.removeAll(new ArrayList<>(Arrays.asList(noField)));
        return list.toArray(new String[0]);
    }
}